{extend name="public/world"}
{block name="style"}{/block}
{block name="container"}
<div class="layui-fluid">
    <div class="layui-card">
        <div class="layui-card-body">
            <table class="layui-hide" id="dataTable" lay-filter="dataTable"></table>
        </div>
    </div>
</div>
{/block}
{block name="script"}
<script type="text/html" id="barDemo">
    {{# if(d.id > 0) { }}
    <a href="{:url('/projects.Produce/show')}?id={$pro.id}&op=swimlaneEdit&sid={{ d.id }}" class="layui-btn layui-btn-xs j-iframe-pop" lxb-data="{width: '560px', height: '325px',domtop:true}" title="修改泳道">修改</a>
    <a href="{:url('/projects.Produce/show')}?id={$pro.id}&op=swimlaneDel&sid={{ d.id }}" class="layui-btn layui-btn-xs layui-btn-danger j-tr-del">删除</a>
    {{# } }}
</script>
<script type="text/html" id="toolbar">
    <div class="layui-btn-group fl">
        <a href="{:url('/projects.Produce/show')}?id={$pro.id}&op=swimlaneAdd" class="layui-btn layuiadmin-btn-admin j-iframe-pop" lxb-data="{width: '560px', height: '325px',domtop:true}" title="添加泳道">添加泳道</a>
    </div>
</script>
<script>
    layui.use(['form','table','element'], function() {
        var $ = layui.jquery
            , form = layui.form
            , table = layui.table
            , element = layui.element;

        var AtableIns = table.render({
            elem: '#dataTable'
            ,url: "{:url('/projects.Produce/show')}?id={$pro.id}&op=swimlane" //数据接口
            ,where: {}
            ,page: false //开启分页
            ,skin: 'row'
            //,size: 'lg'
            ,even: true
            ,limit: 10
            ,text: {
                none : '暂无泳道'
            }
            ,toolbar: '#toolbar'
            ,defaultToolbar: false
            ,cols: [[ //表头
                {field: 'name', width: 180, title: '泳道名称'}
                ,{field: 'description', title: '描述'}
                ,{fixed: 'right', width: 120, title: '操作', templet: '#barDemo'}
            ]]
        });
    });
</script>
{/block}